
let interval = setInterval((name) => {
  console.log('你好：' + name);
}, 3000);

let timer = setTimeout((interval) => {
  clearInterval(interval)
  console.log('cleared timer')
}, 30000, interval);


timer.unref();

console.log('waiting on timer....')

// node 定时器

setInterval(() => {
  
}, interval);

setTimeout(() => {
  
}, timeout);

setImmediate( () => {
  
} )